#ifndef LANDDIALOG_H
#define LANDDIALOG_H

#include <QDialog>
#include "widget.h"
#include "struct.h"

namespace Ui {
class landDialog;
}

extern QVector<QTcpSocket *> sockvector;
extern int op_ip;
extern admin user;
extern server_to_client from_server;
extern config maxmin;
extern dev1 dev;

extern QVector<env_data1> month_data;
extern QVector<env_data1> week_data;
extern bool bFlag_addSeries;

class landDialog : public QDialog
{
    Q_OBJECT

public:
    explicit landDialog(QWidget *parent = 0);
    ~landDialog();
    int op = 0;
    int flag;

    admin user;

    void back();
    void connect_to_host();

signals:
    void recv();

private slots:

    void freshslot();

    void recvslot();

    void on_pushButton_land_clicked();

    void on_pushButton_exit_clicked();

    void registerslot();

    void on_pushButton_register_clicked();

private:
    Ui::landDialog *ui;
    QString myIP;
    int lock = 0;
    int isregister = 0;

};

#endif // LANDDIALOG_H
